package cn.zktr.Personnel.model.pojos;

import java.io.Serializable;
import javax.persistence.*;
import java.util.List;


/**
 * The persistent class for the per_cwa_rsn database table.
 * 
 */
@Entity
@Table(name="per_cwa_rsn")
@NamedQuery(name="PerCwaRsn.findAll", query="SELECT p FROM PerCwaRsn p")
public class PerCwaRsn implements Serializable {
	private static final long serialVersionUID = 1L;

	@Id
	private int rsnid;

	private String rsnreason;

	private String rsnrem;

	//bi-directional many-to-one association to PerCwaCwas
	@OneToMany(mappedBy="perCwaRsn")
	private List<PerCwaCwas> perCwaCwas;

	//bi-directional many-to-one association to PerCwaFid
	@OneToMany(mappedBy="perCwaRsn")
	private List<PerCwaFid> perCwaFids;

	//bi-directional many-to-one association to PerCwaQts
	@OneToMany(mappedBy="perCwaRsn")
	private List<PerCwaQts> perCwaQts;

	//bi-directional many-to-one association to PerCwaRes
	@OneToMany(mappedBy="perCwaRsn")
	private List<PerCwaRes> perCwaRes;

	//bi-directional many-to-one association to PerCwaSst
	@OneToMany(mappedBy="perCwaRsn")
	private List<PerCwaSst> perCwaSsts;

	public PerCwaRsn() {
	}

	public int getRsnid() {
		return this.rsnid;
	}

	public void setRsnid(int rsnid) {
		this.rsnid = rsnid;
	}

	public String getRsnreason() {
		return this.rsnreason;
	}

	public void setRsnreason(String rsnreason) {
		this.rsnreason = rsnreason;
	}

	public String getRsnrem() {
		return this.rsnrem;
	}

	public void setRsnrem(String rsnrem) {
		this.rsnrem = rsnrem;
	}

	public List<PerCwaCwas> getPerCwaCwas() {
		return this.perCwaCwas;
	}

	public void setPerCwaCwas(List<PerCwaCwas> perCwaCwas) {
		this.perCwaCwas = perCwaCwas;
	}

	public PerCwaCwas addPerCwaCwa(PerCwaCwas perCwaCwa) {
		getPerCwaCwas().add(perCwaCwa);
		perCwaCwa.setPerCwaRsn(this);

		return perCwaCwa;
	}

	public PerCwaCwas removePerCwaCwa(PerCwaCwas perCwaCwa) {
		getPerCwaCwas().remove(perCwaCwa);
		perCwaCwa.setPerCwaRsn(null);

		return perCwaCwa;
	}

	public List<PerCwaFid> getPerCwaFids() {
		return this.perCwaFids;
	}

	public void setPerCwaFids(List<PerCwaFid> perCwaFids) {
		this.perCwaFids = perCwaFids;
	}

	public PerCwaFid addPerCwaFid(PerCwaFid perCwaFid) {
		getPerCwaFids().add(perCwaFid);
		perCwaFid.setPerCwaRsn(this);

		return perCwaFid;
	}

	public PerCwaFid removePerCwaFid(PerCwaFid perCwaFid) {
		getPerCwaFids().remove(perCwaFid);
		perCwaFid.setPerCwaRsn(null);

		return perCwaFid;
	}

	public List<PerCwaQts> getPerCwaQts() {
		return this.perCwaQts;
	}

	public void setPerCwaQts(List<PerCwaQts> perCwaQts) {
		this.perCwaQts = perCwaQts;
	}

	public PerCwaQts addPerCwaQt(PerCwaQts perCwaQt) {
		getPerCwaQts().add(perCwaQt);
		perCwaQt.setPerCwaRsn(this);

		return perCwaQt;
	}

	public PerCwaQts removePerCwaQt(PerCwaQts perCwaQt) {
		getPerCwaQts().remove(perCwaQt);
		perCwaQt.setPerCwaRsn(null);

		return perCwaQt;
	}

	public List<PerCwaRes> getPerCwaRes() {
		return this.perCwaRes;
	}

	public void setPerCwaRes(List<PerCwaRes> perCwaRes) {
		this.perCwaRes = perCwaRes;
	}

	public PerCwaRes addPerCwaRe(PerCwaRes perCwaRe) {
		getPerCwaRes().add(perCwaRe);
		perCwaRe.setPerCwaRsn(this);

		return perCwaRe;
	}

	public PerCwaRes removePerCwaRe(PerCwaRes perCwaRe) {
		getPerCwaRes().remove(perCwaRe);
		perCwaRe.setPerCwaRsn(null);

		return perCwaRe;
	}

	public List<PerCwaSst> getPerCwaSsts() {
		return this.perCwaSsts;
	}

	public void setPerCwaSsts(List<PerCwaSst> perCwaSsts) {
		this.perCwaSsts = perCwaSsts;
	}

	public PerCwaSst addPerCwaSst(PerCwaSst perCwaSst) {
		getPerCwaSsts().add(perCwaSst);
		perCwaSst.setPerCwaRsn(this);

		return perCwaSst;
	}

	public PerCwaSst removePerCwaSst(PerCwaSst perCwaSst) {
		getPerCwaSsts().remove(perCwaSst);
		perCwaSst.setPerCwaRsn(null);

		return perCwaSst;
	}

}